Code Generator for LinkItONE

Moderators: lily.li, violet, salmanfarisvp

matthew
Pre-kindergarten
Pre-kindergarten
Posts: 27
Joined: Mon Dec 29, 2014 2:11 pm

Code Generator for LinkItONE

Post by matthew » Sun Jan 04, 2015 10:36 am

I extending pfodDesigner to support LinkItONE.
When complete it will generate code for bluetooth, wifi or SMS connections between LinkItONE and pfodApp
for menu driven control.

More details to follow.

User avatar
loovee
Elementary-3
Elementary-3
Posts: 352
Joined: Fri Nov 02, 2012 9:15 am

Re: Code Generator for LinkItONE

Post by loovee » Sun Jan 04, 2015 5:29 pm

cool~
does it a schedule for it?
If there's anything need my help, please tell me.

matthew
Pre-kindergarten
Pre-kindergarten
Posts: 27
Joined: Mon Dec 29, 2014 2:11 pm

Re: Code Generator for LinkItONE

Post by matthew » Mon Jan 05, 2015 6:58 pm

I have just released pfodApp with SMS connections and updated pfodDesigner with SMS support using the Seeed Studio's SIM900 shield and published the Arduino support libraries (http://www.forward.com.au/pfod/pfodPars ... index.html)

For details of the SMS connection design see http://www.forward.com.au/pfod/pfodSMS/ ... esign.html

Currently awaiting arrival of my LinkItONE board to migrate the SMS library to it and update pfodDesigner. So you could ask them to hurry up and send the board.

In the mean time I am writing up a sample project, turning the house Hot Water heater on and off via SMS so you can turn the hot water on before you arrive home after being away (and check you turned it off when you went)

zhougongming85
Pre-kindergarten
Pre-kindergarten
Posts: 1
Joined: Tue Jan 06, 2015 9:40 am

Re: Code Generator for LinkItONE

Post by zhougongming85 » Tue Jan 06, 2015 10:43 am

Could you use pfodApp to gain the GPS longitude and latitude information of the linkit one, then call map and show the Linkit one's location on the map? thanks

matthew
Pre-kindergarten
Pre-kindergarten
Posts: 27
Joined: Mon Dec 29, 2014 2:11 pm

Re: Code Generator for LinkItONE

Post by matthew » Tue Jan 06, 2015 11:12 am

I assume you need Android's map, in that case no.
Might be a useful addition.

Check out http://www.forward.com.au/pfod/pfodSpecification.pdf for the current functionality provided by pfodApp.

matthew
Pre-kindergarten
Pre-kindergarten
Posts: 27
Joined: Mon Dec 29, 2014 2:11 pm

Re: Code Generator for LinkItONE

Post by matthew » Sat Jan 10, 2015 3:51 pm

Just put up an example SMS project using SeeedStudio's SIM900 GPRS shield. All the code is generated for you by pfodDesinger
http://www.forward.com.au/pfod/pfodSMS/ ... index.html

matthew
Pre-kindergarten
Pre-kindergarten
Posts: 27
Joined: Mon Dec 29, 2014 2:11 pm

Re: Code Generator for LinkItONE

Post by matthew » Sat Jan 17, 2015 2:03 pm

Version 1.2.564 of pfodDesigner has been released and has experimental support for LinkIt ONE bluetooth connection.
pfodDesigner is available free on GooglePlay

In the Generate Code menu click on Serial to change the connection and scroll down to the LinkIt ONE bluetooth connection.
It is marked as experimental because V1.0.42 of LinkIt ONE library stops accepting bluetooth connections after a few mins.
Hopefully this will be fixed with the next update to the library and firmware.
Last edited by matthew on Mon Jan 19, 2015 4:07 pm, edited 1 time in total.

matthew
Pre-kindergarten
Pre-kindergarten
Posts: 27
Joined: Mon Dec 29, 2014 2:11 pm

Re: Code Generator for LinkItONE

Post by matthew » Mon Jan 19, 2015 4:07 pm

Version 1.2.565 of pfodDesigner has been released and has experimental support for LinkIt ONE Wifi connection.
pfodDesigner is available free on GooglePlay

In the Generate Code menu click on Serial to change the connection and scroll down to the LinkIt ONE Wifi connection.
It is marked as experimental because V1.0.42 of LinkIt ONE library will not accept any more wifi connections if the current client does not exit cleanly.
Hopefully this and the other problems will be fixed with the next update to the library and firmware.

matthew
Pre-kindergarten
Pre-kindergarten
Posts: 27
Joined: Mon Dec 29, 2014 2:11 pm

Re: Code Generator for LinkItONE

Post by matthew » Sun Feb 01, 2015 8:00 am

I am now working on SMS connections to LinkIt ONE.

As preparation I have modified pfodSecurity library to remove all the Atmel 8bit AVR assembler and replace it with C code.

However I have now come across another issue.
How to access eeprom on LinkIt ONE

As part of the security (see http://www.forward.com.au/pfod/secureCh ... index.html for all the details)
I store the password and the number of connections and the number of power cycles in eeprom.

When I compile the Arduino code I get this error
....\Arduino\libraries\pfodParser\pfodMAC.cpp:12:24: fatal error: avr/eeprom.h: No such file or directory
#include <avr/eeprom.h>


So I need to start using the EEPROM library instead.

matthew
Pre-kindergarten
Pre-kindergarten
Posts: 27
Joined: Mon Dec 29, 2014 2:11 pm

Re: Code Generator for LinkItONE

Post by matthew » Sun Feb 01, 2015 4:58 pm

Changed to using EEPROM library to remove the above compile error.

Two problems
i) #include <EEPROM.h> does not work in my .cpp file inside my library directory libraries/pfodParser ...
I need to put a copy of this include in the main sketch to get the pre-processing to set up the correct include paths.

ii) LinkIt ONE does not use EEPROM.h instead it uses LEEPROM.h, which again needs to be put in the main sketch also.
This means I will need to have two slightly different copies of the pfodParser library, one for 'standard' Arduino and one for LinkIt ONE

Post Reply