Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Arduino service #812

Closed
wants to merge 621 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
621 commits
Select commit Hold shift + click to select a range
005ab29
Update UI
billonalex May 12, 2020
90521f2
Update logs in back
billonalex May 12, 2020
6919258
Arduino code link
billonalex May 12, 2020
039dea0
arduino code link
billonalex May 12, 2020
f6c1d2f
Devices : Add pulse length
billonalex May 13, 2020
b14e416
Correction
billonalex May 13, 2020
b975ef9
Test on emit 433
billonalex May 13, 2020
8cb3853
Add pulse length for chacon
billonalex May 13, 2020
cfa95f8
add updatePulseLength action
billonalex May 13, 2020
998a3d3
test pulse length
billonalex May 13, 2020
de65230
Test bit length for ir
billonalex May 13, 2020
f3fd304
change bit length by function
billonalex May 13, 2020
dfd575c
Add bit length in JSON message for arduino
billonalex May 13, 2020
9ff2911
Update arduino code + Add 1 manufacturer
billonalex May 13, 2020
cca4be2
Test push button
billonalex May 14, 2020
6572a7e
Correction
billonalex May 14, 2020
975ba6f
Push button for IR
billonalex May 14, 2020
8cb748f
Add IR Library
billonalex May 14, 2020
7599c0c
Back : flash card with Gladys (Running...)
billonalex May 14, 2020
125a513
add upload button
billonalex May 14, 2020
05c0821
Correction
billonalex May 14, 2020
db506f6
Correction
billonalex May 14, 2020
0992f40
Update model
billonalex May 14, 2020
31ca8fd
Update setup.js
billonalex May 14, 2020
85e7282
test upload code
billonalex May 14, 2020
368f4a0
Correction
billonalex May 14, 2020
51325bb
Add upload code function on button
billonalex May 14, 2020
6fc7019
test upload
billonalex May 14, 2020
389394b
Test upload
billonalex May 14, 2020
3c015ad
Add hex code
billonalex May 14, 2020
d337152
Correction
billonalex May 15, 2020
5038513
Correction
billonalex May 15, 2020
3fd7548
Test
billonalex May 15, 2020
7fa2910
Correction
billonalex May 15, 2020
c17b866
Test
billonalex May 15, 2020
bf0ba88
Test
billonalex May 15, 2020
8347945
Test
billonalex May 15, 2020
f0f70ee
Test
billonalex May 15, 2020
0502846
Test
billonalex May 15, 2020
7cfb8c7
Clean front code
billonalex May 15, 2020
adb7476
Correction
billonalex May 16, 2020
f0c1557
Add features : test
billonalex May 16, 2020
aa32851
Correction
billonalex May 16, 2020
9ebd52a
correction
billonalex May 16, 2020
61c0b03
Test
billonalex May 16, 2020
280be25
Upload message
billonalex May 16, 2020
c24375d
Correction
billonalex May 16, 2020
ec0e60b
Test icon
billonalex May 17, 2020
35e4104
Add upload for nano and yun
billonalex May 17, 2020
17df23c
Update API Arduino
billonalex May 17, 2020
1fb1f25
Test flash with bootloader
billonalex May 17, 2020
5bf62f1
Correction
billonalex May 17, 2020
076d5fc
Update recv + test
billonalex May 17, 2020
53f00a0
Test
billonalex May 17, 2020
4241464
Test
billonalex May 17, 2020
6a67da3
Correction
billonalex May 17, 2020
5c37a0d
Update arduino code
billonalex May 18, 2020
59c7ead
Update arduino code
billonalex May 18, 2020
a28f562
Add recv
billonalex May 19, 2020
cad7aea
Update setValue
billonalex May 19, 2020
36f78c0
Update
billonalex May 19, 2020
74b686c
New test
billonalex May 19, 2020
a489d83
Update
billonalex May 19, 2020
51f72f9
Test parser
billonalex May 19, 2020
57eaa3d
Correction
billonalex May 19, 2020
23f75c5
Arduino in new Gladys version
billonalex May 19, 2020
fd57e55
test
billonalex May 19, 2020
47d61ba
Test device reception 433
billonalex May 19, 2020
be1cc09
test receive on save
billonalex May 19, 2020
1ddfdf6
Test
billonalex May 19, 2020
85169be
Test
billonalex May 19, 2020
505e9fa
Test
billonalex May 19, 2020
f2bfac8
Test
billonalex May 20, 2020
a388402
Test
billonalex May 20, 2020
58eb5fb
Test
billonalex May 20, 2020
a859c46
Test
billonalex May 20, 2020
fc81cbb
Update icon
billonalex May 20, 2020
a0c4b4e
Test recv on device 433
billonalex May 20, 2020
14f750a
Correction data pin
billonalex May 20, 2020
e7c2811
recv : test update param
billonalex May 20, 2020
a4f6a6b
Correction
billonalex May 20, 2020
f34a72c
correction
billonalex May 20, 2020
ddee3d3
test
billonalex May 20, 2020
311ddb8
Correction + doc
billonalex May 20, 2020
f6029e0
Correction
billonalex May 20, 2020
0c61542
Correction
billonalex May 20, 2020
3ca755f
Correction
billonalex May 20, 2020
d03cef4
Correction
billonalex May 20, 2020
e099f25
test
billonalex May 20, 2020
eb587b2
Test
billonalex May 20, 2020
0881ece
Correction code
billonalex May 20, 2020
2d58b9f
Update Arduino code
billonalex May 20, 2020
5410668
Update USB API : add serial number
billonalex May 20, 2020
0010d13
Update USB API : add IDs
billonalex May 20, 2020
38464b5
Add Arduino properties in DB
billonalex May 20, 2020
309cbf1
Correction actions.js
billonalex May 20, 2020
e9f73c3
Correction
billonalex May 20, 2020
b58e197
Update
billonalex May 20, 2020
3e78ed2
Add flashing message + usb by serial number
billonalex May 20, 2020
9cf213b
Correction
billonalex May 20, 2020
be786f7
Correction uploading code
billonalex May 20, 2020
ee2043d
Test
billonalex May 20, 2020
272aeb2
Correction
billonalex May 20, 2020
1e90df7
Correction
billonalex May 20, 2020
1f13061
Test
billonalex May 20, 2020
985a269
Flashing : new exception
billonalex May 20, 2020
355538c
Test
billonalex May 20, 2020
0b128b9
Update features view
billonalex May 20, 2020
db94a93
Add bit length for switches
billonalex May 20, 2020
f203bb9
Add Arduino properties in Settings view
billonalex May 20, 2020
9838845
Update device DB params
billonalex May 22, 2020
e5360c6
Correction
billonalex May 22, 2020
f1c3def
Correction Features
billonalex May 22, 2020
2e5af86
Correction
billonalex May 22, 2020
34c19fe
Update recv
billonalex May 22, 2020
da1a07b
recv : Check if data is a json
billonalex May 22, 2020
d56aab7
Add feature value
billonalex May 22, 2020
112838b
Correction
billonalex May 22, 2020
d4b1404
Correction
billonalex May 22, 2020
b648914
Debug
billonalex May 22, 2020
942865c
Correction sensor
billonalex May 23, 2020
a18e7a1
Reception : Test of poll method
billonalex May 23, 2020
4c46df0
New test
billonalex May 24, 2020
45dd977
Update poll function
billonalex May 24, 2020
7d49a96
New test
billonalex May 24, 2020
8dd3355
Update
billonalex May 24, 2020
6edb64a
Change poll frequency
billonalex May 24, 2020
2654a2a
Correction
billonalex May 24, 2020
2d6556f
Test
billonalex May 24, 2020
4f8e98a
Update read only for sensor
billonalex May 24, 2020
95aefc4
Debug
billonalex May 24, 2020
860122f
Update arduino code
billonalex May 24, 2020
c078ad7
Update code : add servo
billonalex May 24, 2020
8db52a1
Update UI for recv
billonalex May 24, 2020
256819f
Add DHT in UI
billonalex May 24, 2020
123a8af
Correction
billonalex May 24, 2020
6d5cf22
Poll : condition on function_name
billonalex May 24, 2020
7c39db8
Add poll : update code
billonalex May 24, 2020
01069e9
Correction poll
billonalex May 24, 2020
f3be4bb
Debug
billonalex May 24, 2020
f9f7b1f
Debug
billonalex May 24, 2020
0601697
Correction humidity
billonalex May 24, 2020
8579321
Add arduino libraries in Git
billonalex May 24, 2020
873e070
Update arduino code + poll
billonalex May 24, 2020
5e0c237
Add unit for temperature + humidity
billonalex May 24, 2020
3bcd5f5
Update Arduino code + HEX files
billonalex May 24, 2020
418e8c7
Update arduino poll
billonalex May 25, 2020
0c18a48
Debug poll
billonalex May 25, 2020
c4a6ea7
Correction poll frequency
billonalex May 25, 2020
1b599e2
Update poll frequency
billonalex May 25, 2020
eec0ea6
Arduino API : Add configuration of device
billonalex May 25, 2020
92ba86f
Update setValue : add switch for IR
billonalex May 25, 2020
f314c4d
setValue : add switch for emit_433
billonalex May 25, 2020
66b4324
Update button device in dashboard
billonalex May 25, 2020
967a599
Update dashboard
billonalex May 25, 2020
ad426f8
Remove option poll : 100 ms
billonalex May 25, 2020
4bf1e76
Prettier
billonalex May 25, 2020
fcdd8e5
Add init function
billonalex May 25, 2020
83954df
API : add init + init on arduino save
billonalex May 25, 2020
685fcd3
Test : init on delete (update reception)
billonalex May 25, 2020
407273c
Correction
billonalex May 25, 2020
57e20ad
Add motion and opening sensor
billonalex May 25, 2020
a6175b6
Correction opening sensor
billonalex May 25, 2020
d672966
Correction affichage UI
billonalex May 25, 2020
eec83b1
First tests
billonalex May 25, 2020
61e71b6
eslint + listen/init functions
billonalex May 25, 2020
c6d9c1e
Check if port opened
billonalex May 25, 2020
ff2bc71
Debug listen
billonalex May 25, 2020
c0aaab6
eslint on init.js
billonalex May 25, 2020
ade9a41
Cleaning init.js
billonalex May 25, 2020
8c2a438
Cleaning init.js
billonalex May 25, 2020
700acad
Test init without listen
billonalex May 25, 2020
1afcc4e
Debug
billonalex May 25, 2020
8207ff1
Debug
billonalex May 25, 2020
6406f80
Correction
billonalex May 25, 2020
bbdf089
Debug
billonalex May 25, 2020
37afe3e
Front : Add listen for device linked
billonalex May 25, 2020
b96860a
Correction device.configure.js
billonalex May 25, 2020
31b1046
Correction
billonalex May 25, 2020
f45c8b3
Correction
billonalex May 25, 2020
e9127d8
Update scripts in back
billonalex May 25, 2020
e83f977
Correction
billonalex May 25, 2020
315993c
Correction
billonalex May 25, 2020
1f0dfc8
Correction
billonalex May 25, 2020
54640c2
Correction
billonalex May 25, 2020
7f010d8
Clear useless scripts
billonalex May 25, 2020
deca3f2
prettier
billonalex May 25, 2020
1210631
eslint
billonalex May 25, 2020
2fb1747
prettier
billonalex May 25, 2020
5a64d4b
Merge remote-tracking branch 'upstream/master'
billonalex May 25, 2020
c4e7910
prettier
billonalex May 25, 2020
968d2ee
front : eslint OK
billonalex May 25, 2020
6c7c3ff
eslint
billonalex May 25, 2020
6d372ce
Correction
billonalex May 25, 2020
daaa908
prettier + eslint (front)
billonalex May 25, 2020
da2f3ca
back : Optimizing eslint
billonalex May 25, 2020
fe60bba
eslint
billonalex May 25, 2020
74f0aac
Back : eslint OK
billonalex May 25, 2020
9f8f4b4
Working on opening sensor
billonalex May 26, 2020
ad230b6
Correction
billonalex May 26, 2020
84e8985
Back : add condition for opening sensor
billonalex May 26, 2020
67346dd
Correction
billonalex May 26, 2020
a10d0ab
Test opening sensor with exception
billonalex May 26, 2020
c16aba2
Correction
billonalex May 26, 2020
d147aac
Front : add code for motion sensor
billonalex May 26, 2020
b358e83
back : motion value
billonalex May 26, 2020
b058340
Correction
billonalex May 26, 2020
5bc8b36
Front : update max value for motion sensor
billonalex May 26, 2020
a330c9b
Correction front + deviceFeature (back)
billonalex May 26, 2020
3080451
Correction + eslint
billonalex May 26, 2020
7802c7e
[Fix] Brain bug : Get params lights for arduino
billonalex May 26, 2020
d5e7f64
Front + setValue + tests
billonalex May 27, 2020
3150be5
Correction test
billonalex May 27, 2020
3c66e16
Update tests
billonalex May 27, 2020
25d5517
Update tests
billonalex May 27, 2020
e198d2e
Prettier
billonalex May 27, 2020
7a1c0f4
Update params API + test API
billonalex May 27, 2020
fd2a604
prettier
billonalex May 27, 2020
2d82c20
Correction prettier philips-hue
billonalex May 27, 2020
75a4eea
Correction eslint
billonalex May 27, 2020
566a297
Correction API + tests
billonalex May 27, 2020
7082d2e
Correction test for controller
billonalex May 27, 2020
5e3ad2f
Add arduino service in demo.json
billonalex May 27, 2020
355209a
[Debug] : ArduinoController --> Only one param
billonalex May 27, 2020
35faebb
[Debug] : setValue => Opening and motion sensors
billonalex May 27, 2020
375d469
[Fix] : Front => Debug search option, device page
billonalex May 27, 2020
c3a35ea
Update tests
billonalex Jun 2, 2020
15921c1
Prettier
billonalex Jun 2, 2020
6aee7e2
Update tests
billonalex Jun 3, 2020
dee123d
Prettier
billonalex Jun 3, 2020
a794287
Fix events
billonalex Jun 3, 2020
ab632c0
Fix tests
billonalex Jun 3, 2020
feaeb03
Update tests
billonalex Jun 4, 2020
60e31db
Update tests
billonalex Jun 4, 2020
7b3f416
Update test
billonalex Jun 4, 2020
58055dc
Update tests
billonalex Jun 4, 2020
6caa4af
[Fix] => Require in Manager + Tests
billonalex Jun 5, 2020
385f767
[Fix] => New tests
billonalex Jun 5, 2020
2cc148a
[Fix] => Remove only from tests
billonalex Jun 5, 2020
bcfcf17
[Fix] => isJsonString function in separated script
billonalex Jun 5, 2020
4b366c6
[Correction] => Prettier
billonalex Jun 5, 2020
4b621cb
[Fix] => onPortOpen/onPortData functions + tests
billonalex Jun 5, 2020
07d0e54
[Fix] => onPortOpen/onPortData tests
billonalex Jun 6, 2020
74b93cc
[Fix] => Prettier
billonalex Jun 6, 2020
827ef03
[Fix] => Update tests
billonalex Jun 6, 2020
8e35db6
[Fix] => setup tests
billonalex Jun 6, 2020
2077c96
[Update] => Clean code
billonalex Jun 7, 2020
59cede6
[Fix] => Correction code
billonalex Jun 8, 2020
7499354
[Fix] => Prettier on front
billonalex Jun 8, 2020
f7a4b01
[Fix] => Setup tests
billonalex Jun 8, 2020
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 2 additions & 2 deletions .circleci/config.yml
Expand Up @@ -66,7 +66,7 @@ jobs:
sudo ldconfig
- run:
name: Install global dependencies
command: 'sudo npm install typescript node-gyp npm@latest -g'
command: "sudo npm install typescript node-gyp npm@latest -g"
- restore_cache: # special step to restore the dependency cache
# Read about caching dependencies: https://circleci.com/docs/2.0/caching/
key: dependency-cache-{{ checksum "server/package.json" }}-node-12
Expand Down Expand Up @@ -126,7 +126,7 @@ jobs:
- checkout
- run:
name: Build Front
command: 'cd front && npm install && npm run build'
command: "cd front && npm install && npm run build"
- persist_to_workspace:
root: ~/gladys-build
paths:
Expand Down
Binary file added front/src/assets/integrations/cover/arduino.jpg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
7 changes: 7 additions & 0 deletions front/src/components/app.jsx
Expand Up @@ -68,6 +68,8 @@ import ZwaveEditPage from '../routes/integration/all/zwave/edit-page';
import RtspCameraPage from '../routes/integration/all/rtsp-camera';
import XiaomiPage from '../routes/integration/all/xiaomi';
import EditXiaomiPage from '../routes/integration/all/xiaomi/edit-page';
import ArduinoDevicePage from '../routes/integration/all/arduino/device-page';
import ArduinoSetupPage from '../routes/integration/all/arduino/setup-page';

// MQTT integration
import MqttDevicePage from '../routes/integration/all/mqtt/device-page';
Expand Down Expand Up @@ -167,6 +169,11 @@ const AppRouter = connect(
<PhilipsHueSetupPage path="/dashboard/integration/device/philips-hue/setup" />
<PhilipsHueDevicePage path="/dashboard/integration/device/philips-hue/device" />
<Redirect path="/dashboard/integration/device/zwave" to="/dashboard/integration/device/zwave/node" />

<ArduinoDevicePage path="/dashboard/integration/device/arduino/device" />
<ArduinoSetupPage path="/dashboard/integration/device/arduino/setup" />
<Redirect path="/dashboard/integration/device/arduino" to="/dashboard/integration/device/arduino/device" />

<ZwaveNodePage path="/dashboard/integration/device/zwave/node" />
<ZwaveNetworkPage path="/dashboard/integration/device/zwave/network" />
<ZwaveSettingsPage path="/dashboard/integration/device/zwave/settings" />
Expand Down
14 changes: 14 additions & 0 deletions front/src/components/boxs/device-in-room/DeviceRow.jsx
@@ -1,4 +1,5 @@
import BinaryDeviceFeature from './device-features/BinaryDeviceFeature';
import ButtonDeviceFeature from './device-features/ButtonDeviceFeature';
import SensorDeviceFeature from './device-features/SensorDeviceFeature';
import MultilevelDeviceFeature from './device-features/MultiLevelDeviceFeature';

Expand All @@ -23,6 +24,19 @@ const DeviceRow = ({ children, ...props }) => {
updateValue={props.updateValue}
/>
);
} else if (props.deviceFeature.type === 'push') {
return (
<ButtonDeviceFeature
x={props.x}
y={props.y}
device={props.device}
deviceFeature={props.deviceFeature}
roomIndex={props.roomIndex}
deviceIndex={props.deviceIndex}
deviceFeatureIndex={props.deviceFeatureIndex}
updateValue={props.updateValue}
/>
);
}
if (props.deviceFeature.type === 'dimmer') {
return (
Expand Down
@@ -0,0 +1,37 @@
const ButtonDeviceType = ({ children, ...props }) => {
function updateValue() {
props.updateValue(
props.x,
props.y,
props.device,
props.deviceFeature,
props.deviceIndex,
props.deviceFeatureIndex,
props.deviceFeature.last_value === 0 ? 1 : 0
);
}

return (
<tr>
<td>
<i class="fe fe-circle" />
</td>
<td>{props.device.name}</td>
<td class="text-right">
<label>
<input
type="button"
name={props.deviceFeature.id}
value="1"
class="custom-switch-input"
checked={props.deviceFeature.last_value}
onClick={updateValue}
/>
<span class="fe fe-circle" />
</label>
</td>
</tr>
);
};

export default ButtonDeviceType;
166 changes: 166 additions & 0 deletions front/src/config/demo.json
Expand Up @@ -1395,6 +1395,172 @@
]
}
],
"get /api/v1/service/arduino": {
"id": "1dbaeb48-d6d2-4930-b7ca-f17d637a364b",
"name": "Arduino",
"selector": "arduino"
},
"get /api/v1/service/arduino/device": [
{
"id": "8e25bf9a-4b24-4099-a08d-f4afe323c3a7",
"service_id": "1dbaeb48-d6d2-4930-b7ca-f17d637a364b",
"room_id": "null",
"name": "Arduino Mega",
"selector": "arduino-mega",
"model": "card",
"external_id": "51bc71ad-816c-4682-9bc2-6840a5036b74",
"createdAt": "2020-05-25T17: 25: 45.129Z",
"updatedAt": "2020-05-25T17: 25: 45.129Z",
"features": [],
"params": [
{
"id": "5b6c5d6f-8756-46af-bfca-f40bb74a14b4",
"device_id": "8e25bf9a-4b24-4099-a08d-f4afe323c3a7",
"name": "ARDUINO_PATH",
"value": "/dev/ttyACM0",
"createdAt": "2020-05-25T17: 25: 45.168Z",
"updatedAt": "2020-05-25T17: 25: 45.168Z"
},
{
"id": "371e873b-b39e-4b84-a87e-e401ce3678ec",
"device_id": "8e25bf9a-4b24-4099-a08d-f4afe323c3a7",
"name": "ARDUINO_MODEL",
"value": "mega",
"createdAt": "2020-05-25T17: 25: 45.169Z",
"updatedAt": "2020-05-25T17: 25: 45.169Z"
}
],
"room": "null",
"service": {
"id": "1dbaeb48-d6d2-4930-b7ca-f17d637a364b",
"pod_id": "null",
"name": "arduino",
"selector": "arduino",
"version": "0.1.0",
"enabled": "true",
"has_message_feature": "false",
"createdAt": "2020-05-25T17: 07: 00.776Z",
"updatedAt": "2020-05-25T17: 07: 00.776Z"
}
},
{
"id": "779fa305-bb11-4b73-aa4a-accc79743e9b",
"service_id": "1dbaeb48-d6d2-4930-b7ca-f17d637a364b",
"room_id": "cecc52c7-3e67-4b75-9b13-9a8867b0443d",
"name": "Lampe Salon",
"selector": "lampe-salon",
"model": "null",
"external_id": "9965d82b-bc80-4cb5-a60b-c5b0577559f3",
"should_poll": "false",
"poll_frequency": "null",
"createdAt": "2020-05-26T18: 17: 50.969Z",
"updatedAt": "2020-05-26T18: 17: 50.969Z",
"features": [
{
"id": "4412eb0f-e705-444c-aa83-b4d76d634673",
"device_id": "779fa305-bb11-4b73-aa4a-accc79743e9b",
"name": "Lampe Salon",
"selector": "lampe-salon",
"external_id": "9965d82b-bc80-4cb5-a60b-c5b0577559f3",
"category": "light",
"type": "binary",
"read_only": "false",
"keep_history": "false",
"has_feedback": "false",
"unit": "null",
"min": "0",
"max": "1",
"last_value": "0",
"last_value_string": "null",
"last_value_changed": "2020-05-27T01: 44: 03.922Z",
"createdAt": "2020-05-26T18: 17: 50.989Z",
"updatedAt": "2020-05-27T01: 37: 15.610Z"
}
],
"params": [
{
"id": "8e316fbc-1386-4774-b7a4-90e88233c7dc",
"device_id": "779fa305-bb11-4b73-aa4a-accc79743e9b",
"name": "DATA_PIN",
"value": "4",
"createdAt": "2020-05-26T18: 17: 51.007Z",
"updatedAt": "2020-05-26T18: 17: 51.007Z"
},
{
"id": "dabb2541-2e5f-4c8e-a95d-0efd90850ea9",
"device_id": "779fa305-bb11-4b73-aa4a-accc79743e9b",
"name": "FUNCTION",
"value": "emit_433_chacon",
"createdAt": "2020-05-26T18: 17: 51.009Z",
"updatedAt": "2020-05-26T18: 17: 51.009Z"
},
{
"id": "2e6b89f6-396b-412d-bd9f-7477cdf3c9c4",
"device_id": "779fa305-bb11-4b73-aa4a-accc79743e9b",
"name": "ARDUINO_LINKED",
"value": "arduino-mega",
"createdAt": "2020-05-26T18: 17: 51.011Z",
"updatedAt": "2020-05-26T18: 17: 51.011Z"
},
{
"id": "5fdf8a00-575c-4136-ad7b-27330aea47a6",
"device_id": "779fa305-bb11-4b73-aa4a-accc79743e9b",
"name": "CODE",
"value": "0",
"createdAt": "2020-05-26T18: 17: 51.013Z",
"updatedAt": "2020-05-26T18: 17: 51.013Z"
},
{
"id": "6e53cd3e-618b-42c4-8c74-7a42e429ebb1",
"device_id": "779fa305-bb11-4b73-aa4a-accc79743e9b",
"name": "CODE_ON",
"value": "1536116368",
"createdAt": "2020-05-26T18: 17: 51.015Z",
"updatedAt": "2020-05-26T18: 17: 51.015Z"
},
{
"id": "cdbea6fc-0a49-4d82-83c4-b1849281f478",
"device_id": "779fa305-bb11-4b73-aa4a-accc79743e9b",
"name": "CODE_OFF",
"value": "1536116352",
"createdAt": "2020-05-26T18: 17: 51.017Z",
"updatedAt": "2020-05-26T18: 17: 51.017Z"
},
{
"id": "42258fdb-0f3c-4cef-889d-385f39d166d6",
"device_id": "779fa305-bb11-4b73-aa4a-accc79743e9b",
"name": "BIT_LENGTH",
"value": "24",
"createdAt": "2020-05-26T18: 17: 51.019Z",
"updatedAt": "2020-05-26T18: 17: 51.019Z"
},
{
"id": "2614bb79-be14-42c9-a47d-cfab5e8f126d",
"device_id": "779fa305-bb11-4b73-aa4a-accc79743e9b",
"name": "PULSE_LENGTH",
"value": "3",
"createdAt": "2020-05-26T18: 17: 51.021Z",
"updatedAt": "2020-05-26T18: 17: 51.021Z"
}
],
"room": {
"id": "cecc52c7-3e67-4b75-9b13-9a8867b0443d",
"name": "Living Room",
"selector": "living-room"
},
"service": {
"id": "1dbaeb48-d6d2-4930-b7ca-f17d637a364b",
"pod_id": "null",
"name": "arduino",
"selector": "arduino",
"version": "0.1.0",
"enabled": "true",
"has_message_feature": "false",
"createdAt": "2020-05-25T17: 07: 00.776Z",
"updatedAt": "2020-05-25T17: 07: 00.776Z"
}
}
],
"get /api/v1/service/xiaomi": {
"id": "70cb1e17-3b17-4886-83ab-45b00a9e03b1",
"name": "Xiaomi",
Expand Down
81 changes: 81 additions & 0 deletions front/src/config/i18n/en.json
Expand Up @@ -522,6 +522,87 @@
"disconnected": "Disconnected from MQTT broker."
}
},
"arduino": {
"title": "Arduino",
"description": "Control your Arduino devices.",
"deviceTab": "Devices",
"setupTab": "Setup",
"codeInstruction2": "In order to use this service, you need to use an Arduino card with the code written for. You can download this code <a href=\"https://github.com/billonalex/Gladys/blob/master/server/services/arduino/arduino-code/arduino-code.ino\" target=\"_blank\">here</a>.",
"codeInstruction": "In order to use this service, you need to use an Arduino card with the code written for. Please upload the code with the Upload button.",
"status": {
"notConfigured": "Arduino service is not configured, please go to ",
"notConnected": "Arduino card is not connected, please connect a card.",
"setupPageLink": "Arduino configuration page"
},
"device": {
"title": "Arduino Devices",
"arduinoDescription": "List of Arduino devices currently connected or which have been connected to Gladys.",
"search": "Search devices",
"noDevices": "No devices configured yet. Please configure your devices with the New button.",
"arduinoConnected": "Arduino connected",
"arduinoNotConnected": "Arduino card is not connected, please connect a card in the Setup page.",
"noNameLabel": "No name",
"nameLabel": "Name",
"roomLabel": "Room",
"featuresLabel": "Features",
"noFeatures": "No features",
"refreshButton": "Refresh Arduino",
"saveButton": "Save",
"deleteButton": "Delete",
"returnButton": "Return back",
"editButton": "Edit details",
"notFound": "Requested device not found.",
"backToList": "Back to device list",
"saveError": "Error saving or deleting device",
"saveConflictError": "Conflict: Are you sure all device feature external IDs are unique ?",
"functionLabel": "Function",
"dataPinLabel": "Data pin",
"arduinoLinkedLabel": "Arduino linked",
"codeLabel": "Code",
"codeOnLabel": "Code ON",
"codeOffLabel": "Code OFF",
"bitLengthLabel": "Length of the code",
"pulseLengthLabel": "Pulse length"
},
"setup": {
"title": "Arduino Settings",
"arduinoDescription": "To use this service, you need to connect an Arduino card.",
"refreshButton": "Refresh Arduino list",
"nameLabel": "Name of the card",
"arduinoModelLabel": "Select the model of your Arduino",
"arduinoUsbDriverPathLabel": "Select the USB port where your Arduino is connected",
"error": "No Arduino device added yet.",
"connecting": "Connection",
"connected": "Arduino connected.",
"connectionError": "Error while connecting, please check your configuration.",
"notConnected": "Arduino card is not connected, please connect a card.",
"noDevices": "No Arduino devices added yet. Please configure your devices with the New button.",
"flashing": "Flashing card...",
"flashingSuccess": "Flashing done !",
"flashingError": "Flashing failed !",
"connectButton": "Save",
"disconnectButton": "Delete",
"uploadButton": "Upload code"
},
"function": {
"recv433": "Receive in 433 MHz",
"emit433": "Emit in 433 MHz",
"emit433Chacon": "Emit in 433 MHz for Chacon outlets",
"emitIR": "Emit in IR",
"dhtTemperature": "Temperature through DHT11",
"dhtHumidity": "Humidity through DHT11"
},
"features": {
"lightButton": "Light",
"switchButton": "Switch",
"pushButton": "Push button",
"radioSensor": "433 MHz sensor",
"temperatureSensor": "Temperature sensor",
"humiditySensor": "Humidity sensor",
"motionSensor": "Motion sensor",
"openingSensor": "Opening sensor"
}
},
"xiaomi": {
"title": "Xiaomi Home",
"description": "Display Xiaomi home devices.",
Expand Down