Re: [sumo-user] VariableSpeedSigns in TraCI

2023-07-02 Thread Jakob Erdmann
setParameter/getParameter won't do anything here.
Also, for a VSS you still have to list all affected lanes. There is no
automatic detection of downstream lanes. It really just calls
lane.setMaxSpeed internally.
Totally agree on the fun of having visual feedback though (-:

Am So., 2. Juli 2023 um 22:57 Uhr schrieb Sasan Amini :

> To be sure, using the generic functions getParameter() or
> setParameter() won't work in this particular case? or am I using them
> wrong?
>
> On Sun, Jul 2, 2023 at 10:49 PM Sasan Amini  wrote:
> >
> > That seems to be a bit more complicated than I thought.
> > Regarding the workaround, I guess using VSS is more practical because
> > it affects all the downstream lanes (overwrites the vehicle maxSpeed)
> > while using traci.lane.setMaxSpeed would only change the speed limit
> > in the lane where the vss is defined. Moreover, it takes the fun away
> > from the SUMO-GUI by not changing the VSS icons.
> >
> > On Sun, Jul 2, 2023 at 10:38 PM Jakob Erdmann 
> wrote:
> > >
> > > Adding a new traci function requires touching multiple parts of the
> code. As an example, see https://github.com/eclipse/sumo/issues/12568
> > > However, you can achieve the effect of a VSS by calling
> traci.lane.setMaxSpeed
> > >
> > > Am Fr., 30. Juni 2023 um 22:20 Uhr schrieb Sasan Amini <
> amini...@gmail.com>:
> > >>
> > >> Dear all,
> > >> I am trying to implement dynamic traffic control on a freeway using
> > >> variable speed signs. I noticed that the TraCI functions are missing
> > >> for vss so I tried to use the get or set parameter function, which
> > >> didn't work out. I also tried to create the traci functions myself as
> > >> follows, but they also have no effect. What is the right way to add
> > >> such functions to traci?
> > >>
> > >> Thanks,
> > >> Sasan
> > >>
> > >> def getSpeed(self,vssID):
> > >> return
> self._getUniversal(tc.CMD_GET_VARIABLESPEEDSIGN_VARIABLE,'speed',vssID)
> > >> """getSpeed(string)
> > >>
> > >> gets the speed in m/s for the named variable speed sign within the
> last step.
> > >> """
> > >> def setSpeed(self, vssID, speed):
> > >> """setSpeed(string, double)
> > >>
> > >> sets the speed in m/s for the named variable speed sign.
> > >> """
> > >>
> self._setCmd(tc.CMD_SET_VARIABLESPEEDSIGN_VARIABLE,'speed',vssID,speed)
> > >> ___
> > >> sumo-user mailing list
> > >> sumo-user@eclipse.org
> > >> To unsubscribe from this list, visit
> https://www.eclipse.org/mailman/listinfo/sumo-user
> > >
> > > ___
> > > sumo-user mailing list
> > > sumo-user@eclipse.org
> > > To unsubscribe from this list, visit
> https://www.eclipse.org/mailman/listinfo/sumo-user
> ___
> sumo-user mailing list
> sumo-user@eclipse.org
> To unsubscribe from this list, visit
> https://www.eclipse.org/mailman/listinfo/sumo-user
>
___
sumo-user mailing list
sumo-user@eclipse.org
To unsubscribe from this list, visit 
https://www.eclipse.org/mailman/listinfo/sumo-user


Re: [sumo-user] netgenerate right turn only lane

2023-07-02 Thread Jakob Erdmann
if you set --turn-lanes 2 you will get an exclusive left turn lane and one
exclusive right-turn lane.
Is your use case getting only a single right-turn lane without a left-turn
lane?


Am So., 2. Juli 2023 um 17:53 Uhr schrieb Dayuan Tan :

> Dear Community,
>
> Hope you everything goes well~
>
> Could you please help inform me how to create right-turn only lane as the
> right most lane in an edge?
> I know --turn-lanes creates the left-turn only lane at the left most. I
> searched a lot. But didn't find a way to do so.
> Thank you very much!
>
> Sincerely,
> Dayuan
> ___
> sumo-user mailing list
> sumo-user@eclipse.org
> To unsubscribe from this list, visit
> https://www.eclipse.org/mailman/listinfo/sumo-user
>
___
sumo-user mailing list
sumo-user@eclipse.org
To unsubscribe from this list, visit 
https://www.eclipse.org/mailman/listinfo/sumo-user


Re: [sumo-user] VariableSpeedSigns in TraCI

2023-07-02 Thread Sasan Amini
To be sure, using the generic functions getParameter() or
setParameter() won't work in this particular case? or am I using them
wrong?

On Sun, Jul 2, 2023 at 10:49 PM Sasan Amini  wrote:
>
> That seems to be a bit more complicated than I thought.
> Regarding the workaround, I guess using VSS is more practical because
> it affects all the downstream lanes (overwrites the vehicle maxSpeed)
> while using traci.lane.setMaxSpeed would only change the speed limit
> in the lane where the vss is defined. Moreover, it takes the fun away
> from the SUMO-GUI by not changing the VSS icons.
>
> On Sun, Jul 2, 2023 at 10:38 PM Jakob Erdmann  wrote:
> >
> > Adding a new traci function requires touching multiple parts of the code. 
> > As an example, see https://github.com/eclipse/sumo/issues/12568
> > However, you can achieve the effect of a VSS by calling 
> > traci.lane.setMaxSpeed
> >
> > Am Fr., 30. Juni 2023 um 22:20 Uhr schrieb Sasan Amini :
> >>
> >> Dear all,
> >> I am trying to implement dynamic traffic control on a freeway using
> >> variable speed signs. I noticed that the TraCI functions are missing
> >> for vss so I tried to use the get or set parameter function, which
> >> didn't work out. I also tried to create the traci functions myself as
> >> follows, but they also have no effect. What is the right way to add
> >> such functions to traci?
> >>
> >> Thanks,
> >> Sasan
> >>
> >> def getSpeed(self,vssID):
> >> return 
> >> self._getUniversal(tc.CMD_GET_VARIABLESPEEDSIGN_VARIABLE,'speed',vssID)
> >> """getSpeed(string)
> >>
> >> gets the speed in m/s for the named variable speed sign within the last 
> >> step.
> >> """
> >> def setSpeed(self, vssID, speed):
> >> """setSpeed(string, double)
> >>
> >> sets the speed in m/s for the named variable speed sign.
> >> """
> >> self._setCmd(tc.CMD_SET_VARIABLESPEEDSIGN_VARIABLE,'speed',vssID,speed)
> >> ___
> >> sumo-user mailing list
> >> sumo-user@eclipse.org
> >> To unsubscribe from this list, visit 
> >> https://www.eclipse.org/mailman/listinfo/sumo-user
> >
> > ___
> > sumo-user mailing list
> > sumo-user@eclipse.org
> > To unsubscribe from this list, visit 
> > https://www.eclipse.org/mailman/listinfo/sumo-user
___
sumo-user mailing list
sumo-user@eclipse.org
To unsubscribe from this list, visit 
https://www.eclipse.org/mailman/listinfo/sumo-user


Re: [sumo-user] VariableSpeedSigns in TraCI

2023-07-02 Thread Sasan Amini
That seems to be a bit more complicated than I thought.
Regarding the workaround, I guess using VSS is more practical because
it affects all the downstream lanes (overwrites the vehicle maxSpeed)
while using traci.lane.setMaxSpeed would only change the speed limit
in the lane where the vss is defined. Moreover, it takes the fun away
from the SUMO-GUI by not changing the VSS icons.

On Sun, Jul 2, 2023 at 10:38 PM Jakob Erdmann  wrote:
>
> Adding a new traci function requires touching multiple parts of the code. As 
> an example, see https://github.com/eclipse/sumo/issues/12568
> However, you can achieve the effect of a VSS by calling traci.lane.setMaxSpeed
>
> Am Fr., 30. Juni 2023 um 22:20 Uhr schrieb Sasan Amini :
>>
>> Dear all,
>> I am trying to implement dynamic traffic control on a freeway using
>> variable speed signs. I noticed that the TraCI functions are missing
>> for vss so I tried to use the get or set parameter function, which
>> didn't work out. I also tried to create the traci functions myself as
>> follows, but they also have no effect. What is the right way to add
>> such functions to traci?
>>
>> Thanks,
>> Sasan
>>
>> def getSpeed(self,vssID):
>> return 
>> self._getUniversal(tc.CMD_GET_VARIABLESPEEDSIGN_VARIABLE,'speed',vssID)
>> """getSpeed(string)
>>
>> gets the speed in m/s for the named variable speed sign within the last step.
>> """
>> def setSpeed(self, vssID, speed):
>> """setSpeed(string, double)
>>
>> sets the speed in m/s for the named variable speed sign.
>> """
>> self._setCmd(tc.CMD_SET_VARIABLESPEEDSIGN_VARIABLE,'speed',vssID,speed)
>> ___
>> sumo-user mailing list
>> sumo-user@eclipse.org
>> To unsubscribe from this list, visit 
>> https://www.eclipse.org/mailman/listinfo/sumo-user
>
> ___
> sumo-user mailing list
> sumo-user@eclipse.org
> To unsubscribe from this list, visit 
> https://www.eclipse.org/mailman/listinfo/sumo-user
___
sumo-user mailing list
sumo-user@eclipse.org
To unsubscribe from this list, visit 
https://www.eclipse.org/mailman/listinfo/sumo-user


Re: [sumo-user] VariableSpeedSigns in TraCI

2023-07-02 Thread Jakob Erdmann
Adding a new traci function requires touching multiple parts of the code.
As an example, see https://github.com/eclipse/sumo/issues/12568
However, you can achieve the effect of a VSS by calling
traci.lane.setMaxSpeed

Am Fr., 30. Juni 2023 um 22:20 Uhr schrieb Sasan Amini :

> Dear all,
> I am trying to implement dynamic traffic control on a freeway using
> variable speed signs. I noticed that the TraCI functions are missing
> for vss so I tried to use the get or set parameter function, which
> didn't work out. I also tried to create the traci functions myself as
> follows, but they also have no effect. What is the right way to add
> such functions to traci?
>
> Thanks,
> Sasan
>
> def getSpeed(self,vssID):
> return
> self._getUniversal(tc.CMD_GET_VARIABLESPEEDSIGN_VARIABLE,'speed',vssID)
> """getSpeed(string)
>
> gets the speed in m/s for the named variable speed sign within the last
> step.
> """
> def setSpeed(self, vssID, speed):
> """setSpeed(string, double)
>
> sets the speed in m/s for the named variable speed sign.
> """
> self._setCmd(tc.CMD_SET_VARIABLESPEEDSIGN_VARIABLE,'speed',vssID,speed)
> ___
> sumo-user mailing list
> sumo-user@eclipse.org
> To unsubscribe from this list, visit
> https://www.eclipse.org/mailman/listinfo/sumo-user
>
___
sumo-user mailing list
sumo-user@eclipse.org
To unsubscribe from this list, visit 
https://www.eclipse.org/mailman/listinfo/sumo-user


[sumo-user] netgenerate right turn only lane

2023-07-02 Thread Dayuan Tan
Dear Community,

Hope you everything goes well~

Could you please help inform me how to create right-turn only lane as the right 
most lane in an edge?
I know --turn-lanes creates the left-turn only lane at the left most. I 
searched a lot. But didn't find a way to do so.
Thank you very much!

Sincerely,
Dayuan___
sumo-user mailing list
sumo-user@eclipse.org
To unsubscribe from this list, visit 
https://www.eclipse.org/mailman/listinfo/sumo-user