can post project if needed
Posted: Sat Oct 06, 2012 2:21 pm
I have done an interface board for pedagogic purpose for curses about PLC
the project i have done is an interface card based on olimex p407 wich permit the plc to pilot
a lynx robotic arm http://www.lynxmotion.com/c-124-al5a.aspx from
a modicon PLC
on output i have 5 pwm
on input i can choose between 5 modes :
* console based ui over serial usb, i use a slightly modified version of microrl
* PLC : logical level (5 for action, 5 for direction)
* PLC : analog level (5 for absolute position)
* PLC : modbus over serial, RTU or ascii (using freemodbus library)
* PLC : modbus over tco, RTU or ascii (using freemodbus library and lwip)
I store permanent state in flash using the last 128ko of eeprom with a mechanism to
reduce wear.
debug message and log are printed on the lcd 6610 screen, in bit banging mode, (this screen use 9 bit spi) in the future, i will
use a olimex E407 instead of P407, so i will connect the screen to an usart configured in synchronous 9 bit mode to use it as spi and
avoid bit banging.
i use chibios hal for all peripheral access,
i use fpu, ccm ram as heap for malloc/free, rtc (saved by battery), gpt, adc, uart, serial over usb, pwm, time
compile with the linaro gcc recommanded toolchain
in fact, nothing new, i have used example form chibios as inspiration, and a lot of open source code found on the net, but it's a working project, so if
someone things it can help, i will put the tar.gz somewhere.
thanks again to the chibios team to give us a so well designed piece of code
Alexandre
the project i have done is an interface card based on olimex p407 wich permit the plc to pilot
a lynx robotic arm http://www.lynxmotion.com/c-124-al5a.aspx from
a modicon PLC
on output i have 5 pwm
on input i can choose between 5 modes :
* console based ui over serial usb, i use a slightly modified version of microrl
* PLC : logical level (5 for action, 5 for direction)
* PLC : analog level (5 for absolute position)
* PLC : modbus over serial, RTU or ascii (using freemodbus library)
* PLC : modbus over tco, RTU or ascii (using freemodbus library and lwip)
I store permanent state in flash using the last 128ko of eeprom with a mechanism to
reduce wear.
debug message and log are printed on the lcd 6610 screen, in bit banging mode, (this screen use 9 bit spi) in the future, i will
use a olimex E407 instead of P407, so i will connect the screen to an usart configured in synchronous 9 bit mode to use it as spi and
avoid bit banging.
i use chibios hal for all peripheral access,
i use fpu, ccm ram as heap for malloc/free, rtc (saved by battery), gpt, adc, uart, serial over usb, pwm, time
compile with the linaro gcc recommanded toolchain
in fact, nothing new, i have used example form chibios as inspiration, and a lot of open source code found on the net, but it's a working project, so if
someone things it can help, i will put the tar.gz somewhere.
thanks again to the chibios team to give us a so well designed piece of code
Alexandre