generate_speed_zones_files()
  • 1 Minute to read

generate_speed_zones_files()


Article summary

generate_speed_zones_files()

Generates the speedmask.yaml and speedmask.pgm files. The speed_mask.pgm file can be modified to draw over low speed zones. White (255, 255, 255) is considered 100% speed and black (0, 0, 0) 0% speed.

Reference

Arguments

ArgumentsTypeDefault value
map_namestringName of the map.

Return

None

Exceptions

  • RayaNavUnkownError

See the complete list of navigation exceptions.

Exceptions

ExceptionCondition
RayaNavUnkownErrorAn unknown error occurs.

See the complete list of Raya Exceptions

Usage Example

Code:

...
class RayaApplication(RayaApplicationBase):

    async def setup(self):
        self.nav = await self.enable_controller('navigation')
        self.map_name = 'map001'
        ...

    async def loop(self):
      ...
      await self.nav.generate_speed_zones_files(self.map_name)
      ...
            
    async def finish(self):
       ...

Was this article helpful?