Skip to content

Commit

Permalink
adjust port for docker, try different general IP for vehicle
Browse files Browse the repository at this point in the history
  • Loading branch information
tdubsFO committed Dec 21, 2023
1 parent dbcbfd1 commit c7fb44e
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ FROM python:3.11-slim
COPY app /app
RUN python -m pip install /app --extra-index-url https://www.piwheels.org/simple

EXPOSE 8000/tcp
EXPOSE 5420/tcp

LABEL version="0.0.1"

Expand All @@ -16,13 +16,13 @@ ARG IMAGE_NAME
LABEL permissions='\
{\
"ExposedPorts": {\
"8000/tcp": {}\
"5420/tcp": {}\
},\
"HostConfig": {\
"Binds":["/root/.config/blueos/extensions/$IMAGE_NAME:/root/.config"],\
"ExtraHosts": ["host.docker.internal:host-gateway"],\
"PortBindings": {\
"8000/tcp": [\
"5420/tcp": [\
{\
"HostPort": ""\
}\
Expand Down
Binary file modified app/.DS_Store
Binary file not shown.
6 changes: 3 additions & 3 deletions app/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@
app = Flask(__name__, static_url_path="/static", static_folder="static") #setup flask app

logging_active = False# Global variable to control the logging
distance_url = 'http://127.0.0.1/mavlink2rest/mavlink/vehicles/1/components/194/messages/DISTANCE_SENSOR' #10.144.19.16
gps_url = 'http://127.0.0.1/mavlink2rest/mavlink/vehicles/1/components/1/messages/GLOBAL_POSITION_INT'
yaw_url= 'http://127.0.0.1/mavlink2rest/mavlink/vehicles/1/components/1/messages/ATTITUDE'
distance_url = 'http://0.0.0.0/mavlink2rest/mavlink/vehicles/1/components/194/messages/DISTANCE_SENSOR' #10.144.19.16
gps_url = 'http://0.0.0.0/mavlink2rest/mavlink/vehicles/1/components/1/messages/GLOBAL_POSITION_INT'
yaw_url= 'http://0.0.0.0/mavlink2rest/mavlink/vehicles/1/components/1/messages/ATTITUDE'
log_file = 'sensordata.csv'
log_rate = 2 #Desired rate in Hz
data = []
Expand Down

0 comments on commit c7fb44e

Please sign in to comment.