SENSORS DATA TO PC IN EXCEL

Discuss PC Developer and Web Developer projects and features here.
Post Reply
CATSTAR
Posts: 18
http://meble-kuchenne.info.pl
Joined: Tue Dec 27, 2022 12:44 pm
Has thanked: 3 times
Been thanked: 1 time

SENSORS DATA TO PC IN EXCEL

Post by CATSTAR »

Hello ! ..I would like to made a new project to read some sensors and send data wireless to PC in excel..I use flowcode9.
I was selected a mcu PIC18F46K22 in TQFP44, and an ESP-8266 module for wifi. As sensors I use a Force Sensor Resistor (FSR) MF01A-N-221-A11 ,an accellerometer MMA-8452 , and a cardiac pulse / oximeter sensor U029 that based in MAX-30100 with I2C interface..I use a pic mcu instead of arduino because I need very small pcb (max 45x30mm)..I would like to have an example on how to made the project with flowcode9...FSR and U029 sensors not supported by Flowcode9..so it will be useful an example of code as similar component for FSR and U029 sensor ..About hardware , sensors MMA-8452 and U029 are connected to PIC with I2C inputs of PIC, FSR sensor connected to an analog input with resistor divider..PIC and ESP-8266 are interfaced with TX , RX. RESET. Sensors data will sent to PC and displayed in excel in real time..
Thanks in advance.
Basil

stefan.erni
Valued Contributor
Posts: 758
Joined: Wed Dec 02, 2020 10:53 am
Has thanked: 149 times
Been thanked: 171 times

Re: SENSORS DATA TO PC IN EXCEL

Post by stefan.erni »

Hi Basil

You made a good choice with Flowcode 9. Also with the App Developer.
I also use a PIC with ESP-8266 before, but now I use an ESP32.
This already has Wifi and Bluetooth built in.
I'm using bluetooth at the moment because I'm not allowed to use the wifi at the office. But I've also used WiFi at home.

Foil sensor, accellerometer I already use with Flowcode and I'm waiting for the component MAX-30100 that Ben has already started. Excel (CSV file) and tables are already supported in Flowcode. But you have to think about how much data you make per second, or do you make measurements every minute or hour?
Can you draw a board and solder a TQFP44? I use Altium to draw boards if you know the program and also make boards about 45mmx30mm size.

I hope it helps you to choose Flowcode

regards

Stefan

CATSTAR
Posts: 18
Joined: Tue Dec 27, 2022 12:44 pm
Has thanked: 3 times
Been thanked: 1 time

Re: SENSORS DATA TO PC IN EXCEL

Post by CATSTAR »

Hi Stefan
Thanks for your answer. Flowcode is an excellent tool especially for those that have little experience about programming.
I'm a project designer, now I'm learning Flowcode. I use a PIC in TQFP44, because I need very small space for mainboard . That will be mobile, so I use a lithium battery for power...I use wifi for better range between PC and mainboard in a terrain of 20x20 meters..PCB design and solder a TQFP44 is easy for me. I've design smaller PCB's than 45x30mm..I use for that PCB design the simpler SprintLayout 6.0 . Altium is for more complex PCB..My goal about measurements is to have samples every second or below that time, and display that data in excel in real time. I don't know what is the sample time limit for those sensor. About MAX30100 component, I hope to have that component before the end of month..Now I'll try to make the code for PIC with Flowcode..I need help from those who have better experience. So,would you like to share a block diagram of code about the sequence of measurements and display in PC ? My e-mail is hatzbs@yahoo.gr , if you like to send you schematic and pcb for better info about my design, please let me know. Every info will helps..
Many thanks.
Basil

chipfryer27
Valued Contributor
Posts: 1146
Joined: Thu Dec 03, 2020 10:57 am
Has thanked: 284 times
Been thanked: 412 times

Re: SENSORS DATA TO PC IN EXCEL

Post by chipfryer27 »

Hi

Following on from Stefan, I'd recommend you spend a little time familiarising yourself with App Developer and the WiKi is a good starting point. This link will take you to the Home Page.

https://www.flowcode.co.uk/wiki/index.p ... =Main_Page

You will find many example of using FC and FAD including many of the sensors. One of the many good features of FC is that code, generally speaking, is not chip specific.

One feature under Debug is "Step Into" and this allows you to simulate your code a step at a time, which is a great way to understand what's going on and when.

Regards

stefan.erni
Valued Contributor
Posts: 758
Joined: Wed Dec 02, 2020 10:53 am
Has thanked: 149 times
Been thanked: 171 times

Re: SENSORS DATA TO PC IN EXCEL

Post by stefan.erni »

Hi Basil

Do you already know how to program the PIC? Do you have an ICD4 or something similar?

Do you know the Microchip Curiosity Nano demo boards? They are with comparable PIC as you want to use.
Maybe you can look there or use one at the beginning

https://www.digikey.ch/de/products/deta ... 8/10270364

regards

Stefan

CATSTAR
Posts: 18
Joined: Tue Dec 27, 2022 12:44 pm
Has thanked: 3 times
Been thanked: 1 time

Re: SENSORS DATA TO PC IN EXCEL

Post by CATSTAR »

Thanks Stefan for info.
Usually I use PICKIT3 to programming PIC mcu. I've made many projects with FLOWCODE7, so is very easy to work with FC9.
About above project, there is no an example code for sensors FSR, MMA8452, MAX30100 that I'll use, neither some info about to how can make a flow chart for macros of that components, in right sequence..
Also there is no an example for DSP input/output CSV , neither an example on how to send data from ESP8266 and display that on a PC in excel...any example about that, in general form or in block diagram will helps to make a flow chart.
About c code how possible is to insert a part of c code in flowchart? there are some codes for above sensors in c for arduino..Is it possible to insert that in flowcode and how? Thanks.

chipfryer27
Valued Contributor
Posts: 1146
Joined: Thu Dec 03, 2020 10:57 am
Has thanked: 284 times
Been thanked: 412 times

Re: SENSORS DATA TO PC IN EXCEL

Post by chipfryer27 »

Hi

A lot of what you are asking is already covered in the WiKi and also in the forums. A search within will probably be very helpful. If you follow my previous link and do a search for C Code Icon you will see how to insert code. Similarly there is a lot of information on how to create your own components.

Regards

stefan.erni
Valued Contributor
Posts: 758
Joined: Wed Dec 02, 2020 10:53 am
Has thanked: 149 times
Been thanked: 171 times

Re: SENSORS DATA TO PC IN EXCEL

Post by stefan.erni »

Hi Basil

I made you a small App as a demo how easy it is to draw a chart with FC9 and save the data in excel.

Load the program and press F5.... then move the joystick at the end right click in the chart

A question about the MMA8452. How would you like to use it? As motion tracking or orientation change, or tap,

About the FSR would you like to use it as tap for switch or more like personal scale?

regards

Stefan
Chart2excel.png
Chart2excel.png (150.64 KiB) Viewed 5014 times
Attachments
JoyStick_Chart.fcsx
(15.3 KiB) Downloaded 248 times

CATSTAR
Posts: 18
Joined: Tue Dec 27, 2022 12:44 pm
Has thanked: 3 times
Been thanked: 1 time

Re: SENSORS DATA TO PC IN EXCEL

Post by CATSTAR »

Hi Stefan
I would like to use MMA8452 as motion tracking, and FSR as personal scale.
to send sensors data, must read and store data to a string variable to send to PC. I can't find an example to use sensor components . about to send data to PC and display that in excel in real time, there is a feature in excel ..data streamer..I'll test it hoping to works...but first must have sensors data..

Post Reply