The embedded main control module adopts the microcontroller lpc2148 based on arm7tdmi-s core, which is highly integrated. Embedded 40KB static RAM and 512KB flash memory, integrated ADC, DAC converter, watchdog, Real-time Clock RTC, 2 UARTS, 2 I2C, SPI and other bus interfaces, and USB2.0 full speed interface. It is convenient to expand USB interface, JTAG debugging interface, touch screen, less external chips, and uses ultra small lqfp64 package, which ensures the miniaturization of the instrument. And the circuit is relatively simple, reducing the cost of development and production. The chip can achieve the highest working frequency of 60MHz and has strong functions, which can meet the requirements of embedded system μ C / OS-II and humanized man-machine interface. All interfaces of lpc2148 are used in this design.
The Ethernet interface adopts integrated Mac with SPI interface and ENC28J60 with 10 Base-T PHY. The cost of the I / O port of the main controller is greatly reduced. ENC28J60 conforms to all IEEE 802.3 specifications and adopts a series of packet filtering mechanisms to restrict incoming packets. It also provides an internal DMA module for fast data throughput and hardware supported IP checksums. The communication with the main controller is realized by two interrupt pins and SPI, and the data transmission rate is up to 10 Mb / s. Two dedicated pins are used to connect led to indicate network activity status.
Figure 2 Ethernet interface circuit diagram
The LED module adopts 20 LEDs with 6 wavelengths. The design of multi wavelength makes the measurement more targeted and the measurement data more effective. Our design can measure the brightness of each led through CCD, and then lpc2148 can control the current through the LED through the point correction function, so as to keep the brightness between the LEDs consistent and further improve the accuracy of measurement. The network chip used in this design is an independent Ethernet controller with SPI interface, which occupies less I / O port of MCU. The CCD module mainly includes the whole power supply, CPLD, linear CCD sensor, operational amplifier and high precision AD converter.