Code: Select all
carlDataJason.py :
* saveCarlData(dataname, datavalue, logit=False) # adds datanaem:datavalue to carlData.json file
* getCarlData(dataname=None) # either returns dictionary with all values, or just value of passed name
* delCarlData(dataname) # delete item from carlData.json
At this point I am only keeping two variables:
* chargingCycles # number of times robot has docked for recharging
* chargeConditioning # count down flag to discharge batteries (dock to recharge) to 7.7v instead of the normal 8.1v if greater than 0.
I am planning to add some more slowly changing variables:
* dockingState [returning, docking, docked, dismounting, notdocked]
* lastDockingStateChange datetime
* chargingState [unknown, discharging, charging, trickling]
* lastChargingStateChange datetime
* drivingProcess [process_name or PID or none] controlling the vehicle position
* tiltpanProcess [process_name or PID or none] controlling the tiltpan (and distance sensor)
* tiltpanCentered boolean (when centered, multple processes can use distance sensor readings)
but eventually, I want to start tracking more dynamic variables such as:
* botInMotion boolean
* currentDrivingCommand?
* currentX,Y,theta (Dock reference) - this is very wishful
* currentOrientationConfidence
* currentPositionConfidence
* tiltpanInMotion
I'm wondering if I need to look at multiprocessing shared memory, or a sqlite3 database, or just continue on as I am?
Eventually, I am sure I'll want to add a DB for tracking driving command history and such, but I'm hesitant to complicate my simple robot life.